import Vue from 'vue'
import VueRouter from 'vue-router'
import HomeView from '../views/HomeView.vue'

Vue.use(VueRouter)

const routes = [
  {
    path: '/',
    name: 'homeview',
    component:()=>import('../views/HomeView.vue')


  },
  {
    path: '/gedanview',
    name: 'gedanview',
    component:()=>import('../views/GeDanView.vue'),
    meta: { showPlayBar: false }


  },
  {
    path: '/player/:id',
    name: 'player',
    component:()=>import('../views/PlayView.vue'),
    meta: { showPlayBar: false }


  },
  {
    path: '/playlist',
    name: 'playlist',
    component:()=>import('../views/PlayListView.vue'),
    meta: { showPlayBar: false }
    


  }
  ,
  {
    path: '/home',
    name: 'home',
    component:()=>import('../views/HomeView.vue'),
    children:[
      {
        path: 'center',
        name: 'center',
        component:()=>import('../components/Home/center.vue')
        
      },
      {
        path: 'index',
        name: 'index',
        component:()=>import('../components/Home/index.vue')
       
      },
      {
        path: 'explore',
        name: 'explore',
        component:()=>import('../components/Home/explore.vue')
        
   
      },
      {
        path: 'search',
        name: 'search',
        component: HomeView,
        component:()=>import('../components/Home/search.vue')
    
      }
      
    ]
  },
  {
    path: '/home',
    name: 'home',
    component:()=>import('../views/HomeView.vue'),
    children:[
      {
        path: 'center',
        name: 'center',
        component:()=>import('../components/Home/center.vue')
        
      },
      {
        path: 'index',
        name: 'index',
        component:()=>import('../components/Home/index.vue')
       
      },
      {
        path: 'explore',
        name: 'explore',
        component:()=>import('../components/Home/explore.vue')
        
   
      },
    
      
    ]
  },
  {
    path: '/love',
    name: 'love',
    component:()=>import('../views/LoveView.vue'),
    meta: { showPlayBar: false }

  },
  {
    path: '/history',
    name: 'history',
    component:()=>import('../views/HistoryView.vue'),
    meta: { showPlayBar: false }

  },
  {
    path: '/singer',
    name: 'singer',
    component:()=>import('../views/SingerView.vue'),
    children:[
      {
        path: 'main',
        name: 'main',
        component:()=>import('../views/MainView.vue'),
        meta: { showPlayBar: false }
        
      },
      {
        path: 'work',
        name: 'work',
        component:()=>import('../views/WorkView.vue'),
        meta: { showPlayBar: false }
       
      },
  
      
    ],
    meta: { showPlayBar: false }


  },
  {
    path: '/square',
    name: 'square',
    
    component:()=>import('../views/SquareView.vue'),
    meta: { showPlayBar: false }

  },


]

const router = new VueRouter({

  routes
  
})

export default router
